package newhiant.hianto2o.com.utils;

import android.databinding.BindingAdapter;
import android.widget.ImageView;

import com.bumptech.glide.Glide;

import newhiant.hianto2o.com.R;

/**
 * Created by Administrator on 2017/8/2 0002.
 */

public class NotStaticUtils {
    @BindingAdapter("imgSrc")
    public void showImg(ImageView imageView,String imgUrl){
        if(imgUrl ==null){
            imageView.setImageResource(R.mipmap.ic_launcher);
        }else {
            Glide.with(imageView.getContext()).load(imgUrl).into(imageView);
        }
    }
}
